Overview | Package | Class | Tree | Deprecated | Index | Help
| Oracle® OLAP Analytic Workspace Java API Reference 10g Release 2 (10.2) B14351-02
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## oracle.AWXML
Class Attribute

    java.lang.Object
      |
      +--oracle.AWXML.BaseObject
            |
            +--oracle.AWXML.Attribute

Direct Known Subclasses:
  AttributeProjection

public class Attribute
extends BaseObject
implements DerivedMeasureInput

A `BaseObject` that represents an attribute of a dimension member. An attribute is some characteristic of a dimension member. For example, a Product dimension might have a color attribute that applies to certain types of products. You can use an attribute to specify a set of dimension members. For a diagram of the associations of the `Attribute` class, see Analytic Workspace Java API Object Model.

An `Attribute` can have an OLAP data type or it can have a domain of a dimension. When a dimension is the domain of an attribute, all attribute values are members of the associated dimension. For the valid data types for an `Attribute`, see the ``setDataType(String input)`` method.

An attribute can have a classification, which supplies it with a predetermined meaning. Classified attributes have specific OLAP data types depending on the classification. The following table lists the `Attribute` classifications, the data type of the classification, and a brief description.

Classification | Data Type | Description
`DEFAULT_ORDER` | Numeric | Position in the default order.
`END_DATE` | Date | Last date in a time period.
`TIME_SPAN` | Numeric | Number of days in a time period.
`MEMBER_LONG_DESCRIPTION` | Text | Long description.
`MEMBER_SHORT_DESCRIPTION` | Text | Short description.
`MEMBER_VISIBLE` | Boolean | Hidden or visible?
`USER` | --- | User-defined.

The `Attribute` class implements the `DerivedMeasureInput` interface. You can therefore use an `Attribute` as am input to calculations that generate derived measures.

In the current release, only a `Dimension` supports `Attribute` objects. To apply an attribute to an object owned by a `Hierarchy` or a `Level`, use an `AttributeProjection`.

Fields inherited from class oracle.AWXML.BaseObject
`DATABASENULL`

Constructor Summary
`Attribute(BaseObject input)` Creates an `Attribute` for the specified `Dimension`.

Method Summary
`java.lang.String` | `Alter(AWConnection connection)` Alters the `Attribute` in the current analytic workspace of the specified database connection.
`java.lang.String` | `Create(AWConnection connection)` Creates the `Attribute` in the current analytic workspace of the specified database connection.
`java.lang.String` | `Delete(AWConnection connection)` Deletes the `Attribute` in the current analytic workspace of the specified database connection.
`java.lang.String` | `getClassification()` Gets the classification of the `Attribute`.
`java.lang.String` | `getDataType()` Gets the data type of the `Attribute`.
`Dimension` | `getDimensionDomain()` Gets the `Dimension` that is the domain of the `Attribute`.
`boolean` | `isDefaultOrder()` Indicates whether the `Attribute` defines the default sort order for the associated `Dimension`.
`boolean` | `isMultiLingual()` Indicates whether the `Attribute` has values for more than one language.
`void` | `setClassification(java.lang.String input)` Specifies the classification of the `Attribute`.
`void` | `setDataType(java.lang.String input)` Specifies the data type of the `Attribute`.
`void` | `setDimensionDomain(Dimension input)` Specifies a `Dimension` as the domain of the `Attribute`.
`void` | `setIsDefaultOrder(boolean input)` Specifies whether the `Attribute` defines the default sort order for the associated `Dimension`.
`void` | `setIsDefaultOrder(java.lang.Boolean input)` Specifies whether the `Attribute` defines the default sort order for the associated `Dimension`.
`void` | `setIsMultiLingual(boolean input)` Specifies whether the `Attribute` has values for more than one language.
`void` | `setIsMultiLingual(java.lang.Boolean input)` Specifies whether the `Attribute` has values for more than one language.
`java.lang.String` | `WriteToXML()` Gets an XML representation of the `Attribute`.

Methods inherited from class oracle.AWXML.BaseObject
`CreateAfter, CreateBefore, CreateFirst, DataRead, getColumnName, getId, getLongName, getLongName, getName, getOwner, getPluralName, getPluralName, getSchema, getShortName, getShortName, setColumnName, setLongName, setLongName, setName, setPluralName, setPluralName, setSchema, setShortName, setShortName`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### Attribute

    public Attribute(BaseObject input)

  Creates an `Attribute` for the specified `Dimension`.
  Parameters:
    `input` - The `Dimension` to own the `Attribute`.

Method Detail

### setDimensionDomain

    public void setDimensionDomain(Dimension input)

  Specifies a `Dimension` as the domain of the `Attribute`. All values of the `Attribute` must be members of the associated dimension. Attributes defined with a dimension domain perform better than attributes with standard data types when the number of unique attribute values is small compared to the size of the owning dimension.
  Parameters:
    `input` - The `Dimension` to use as the domain of this `Attribute`.

### getDimensionDomain

    public Dimension getDimensionDomain()

  Gets the `Dimension` that is the domain of the `Attribute`.
  Returns:
    The `Dimension` that is the domain of the `Attribute`.

### setClassification

    public void setClassification(java.lang.String input)

  Specifies the classification of the `Attribute`. The classification system provides predetermined meanings for specific attributes. The attribute classifications are the following:

         DEFAULT_ORDER
         END_DATE
         TIME_SPAN
         MEMBER_LONG_DESCRIPTION
         MEMBER_SHORT_DESCRIPTION
         MEMBER_VISIBLE
         USER

  To identify an `Attribute` that is used by a foreign tool or application for its own purpose, specify a classification of `USER`.

  Parameters:
    `input` - The classification that you want the `Attribute` to have.

### getClassification

    public java.lang.String getClassification()

  Gets the classification of the `Attribute`.
  Returns:
    A `String` that contains the `Attribute` classification.

### setDataType

    public void setDataType(java.lang.String input)

  Specifies the data type of the `Attribute`. The valid datatypes are the following:

         BOOLEAN
         DATE
         DATETIME
         DECIMAL
         ID
         INTEGER
         LONGINTEGER
         NTEXT
         NUMBER
         TEXT
         SHORTDECIMAL
         SHORTINTEGER

  Parameters:
    `input` - A `String` containing the datatype of the attribute.

### getDataType

    public java.lang.String getDataType()

  Gets the data type of the `Attribute`.
  Returns:
    A `String` that contains the data type of the `Attribute`.

### WriteToXML

    public java.lang.String WriteToXML()

  Gets an XML representation of the `Attribute`.
  Overrides:
    WriteToXML in class BaseObject
  Returns:
    An XML `String` that represents the `Attribute`.

### isDefaultOrder

    public boolean isDefaultOrder()

  Indicates whether the `Attribute` defines the default sort order for the associated `Dimension`.
  Returns:
    A `boolean` that is `true` if the `Attribute` defines the default sort order for the associated `Dimension` or `false` otherwise.

### setIsDefaultOrder

    public void setIsDefaultOrder(boolean input)

  Specifies whether the `Attribute` defines the default sort order for the associated `Dimension`. By default, an `Attribute` does not define the default sort order.
  Parameters:
    `input` - A `boolean` that is `true` if you want the `Attribute` to define the default sort order or `false` otherwise.

### setIsDefaultOrder

    public void setIsDefaultOrder(java.lang.Boolean input)

  Specifies whether the `Attribute` defines the default sort order for the associated `Dimension`. By default, an `Attribute` does not define the default sort order.
  Parameters:
    `input` - A `Boolean` that is `true` if you want the `Attribute` to define the default sort order or `false` otherwise.

### Create

    public java.lang.String Create(AWConnection connection)

  Creates the `Attribute` in the current analytic workspace of the specified database connection.
  Overrides:
    Create in class BaseObject
  Parameters:
    `connection` - The `AWConnection` that specifies the database connection.
  Returns:
    A `String` that contains `success` if this method successfully creates the `Attribute`.

### Alter

    public java.lang.String Alter(AWConnection connection)

  Alters the `Attribute` in the current analytic workspace of the specified database connection.
  Overrides:
    Alter in class BaseObject
  Parameters:
    `connection` - The `AWConnection` that specifies the database connection.
  Returns:
    A `String` that contains `success` if this method successfully alters the `Attribute`.

### Delete

    public java.lang.String Delete(AWConnection connection)

  Deletes the `Attribute` in the current analytic workspace of the specified database connection.
  Overrides:
    Delete in class BaseObject
  Parameters:
    `connection` - The `AWConnection` that specifies the database connection.
  Returns:
    A `String` that contains `success` if this method successfully deletes the `Attribute`.

### setIsMultiLingual

    public void setIsMultiLingual(java.lang.Boolean input)

  Specifies whether the `Attribute` has values for more than one language.
  Parameters:
    `input` - A `Boolean` that indicates whether the `Attribute` has values for more than one language.

### setIsMultiLingual

    public void setIsMultiLingual(boolean input)

  Specifies whether the `Attribute` has values for more than one language.
  Parameters:
    `input` - A `boolean` that indicates whether the `Attribute` has values for more than one language.

### isMultiLingual

    public boolean isMultiLingual()

  Indicates whether the `Attribute` has values for more than one language.
  Returns:
    A `boolean` that is `true` if the `Attribute` has values for more than one language or `false` otherwise.

Overview | Package | Class | Tree | Deprecated | Index | Help
| Oracle® OLAP Analytic Workspace Java API Reference 10g Release 2 (10.2) B14351-02
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2003, 2005 Oracle. All rights reserved.